package com.cmc.cloud.cmclink.doc.vo.specialcargodgvo;

import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;
import org.hibernate.validator.constraints.Length;

import javax.validation.constraints.NotNull;
import java.util.Date;
import java.util.List;

/**
 * 疑似危险品待处理清单 Base VO，提供给添加、修改、详细的子 VO 使用
 * 如果子 VO 存在差异的字段，请不要添加到这里，影响 Swagger 文档生成
 *
 * @author huzheng
 */
@Data
public class SpecialCargoSuspectedDgBaseVO {

    @Schema(description = "主键")
    private Long id;

    @Schema(description = "批量更新的主键")
    private List<Long> ids;

    @Schema(description = "订舱号", requiredMode = Schema.RequiredMode.REQUIRED)
    @Length(max = 50, message = "{specialcargosuspecteddg.bookingno.length}")
    private String bookingNo;

    @Schema(description = "提单号", requiredMode = Schema.RequiredMode.REQUIRED)
    @Length(max = 50, message = "{specialcargosuspecteddg.blno.length}")
    private String blNo;

    @Schema(description = "船名编码", requiredMode = Schema.RequiredMode.REQUIRED)
    @Length(max = 50, message = "{specialcargosuspecteddg.vesselcode.length}")
    private String vesselCode;

    @Schema(description = "航次", requiredMode = Schema.RequiredMode.REQUIRED)
    @Length(max = 50, message = "{specialcargosuspecteddg.voyage.length}")
    private String voyage;

    @Schema(description = "装货港", requiredMode = Schema.RequiredMode.REQUIRED)
    @Length(max = 5, message = "{specialcargosuspecteddg.polcode.length}")
    private String polCode;

    @Schema(description = "卸货港", requiredMode = Schema.RequiredMode.REQUIRED)
    @Length(max = 5, message = "{specialcargosuspecteddg.podcode.length}")
    private String podCode;

    @Schema(description = "货描", example = "随便")
    @Length(max = 500, message = "{specialcargosuspecteddg.cargodescription.length}")
    private String cargoDescription;

    @Schema(description = "是否处理", requiredMode = Schema.RequiredMode.REQUIRED)
    @NotNull(message = "{specialcargosuspecteddg.processingflag.notnull}")
    private String processingFlag;

    @Schema(description = "货物类型", requiredMode = Schema.RequiredMode.REQUIRED, example = "1")
    @Length(max = 20, message = "{specialcargosuspecteddg.cargotype.length}")
    private String cargoType;

    @Schema(description = "是否退关", requiredMode = Schema.RequiredMode.REQUIRED)
    private Boolean withdraw;

    @Schema(description = "备注", example = "随便")
    @Length(max = 200, message = "{specialcargosuspecteddg.remark.length}")
    private String remark;

    @Schema(description = "创建时间")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    private Date createTime;

    @Schema(description = "创建人")
    private String creator;

    @Schema(description = "操作时间")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    private Date updateTime;

    @Schema(description = "操作人")
    private String updater;

}
